<template>
  <div class=''>
      <button @click="add">传值</button>
  </div>
</template>

<script>
export default {
  name: 'MyComponent',
  props: { },
  data () {
    return {
      msg: ''
    }
  },
  methods: {
    add () {
      const shuZi = this.msg + 1
      console.log(shuZi)
      this.$emit('abc', shuZi)
    }
  },
  computed: { },
  created () { },
  mounted () { }
}
</script>

<style scoped lang='less'></style>
